home *** CD-ROM | disk | FTP | other *** search
- Path: news.bellglobal.com!stupy
- From: stupy@freenet.durham.org (Steve Tupy)
- Newsgroups: comp.lang.c
- Subject: Re: strings
- Date: 29 Jan 1996 15:00:52 GMT
- Organization: Durham Free-Net
- Message-ID: <4einf4$330@news.bellglobal.com>
- References: <4eg9qj$1ut4@sp115.ocs.lsu.edu>
- NNTP-Posting-Host: 204.101.165.17
- X-Newsreader: TIN [version 1.2 PL2]
-
- Pradeep Nayar (eenaya@unix1.sncc.lsu.edu) wrote:
- : Hi,
- : I saw this piece of code in a book somewhere.
-
- : ----
- : char *str ;
-
- : str = "hello world"[10] ;
-
- : _________
-
- : what does the second line do?
-
-
- I don't know how you can get this to compile at all! Now if you had this...
-
- char *str = "hello world"; or even
- char *str = { "hello world" };
-
- but don't use the above example, it does not work(at least not over
- here)... Wow, what kind of books are you reading?
-
- --
- Steve
-